//
//  xmlParser.m
//  htpp
//
//  Created by MeMac.cn on 10-4-21.
//  Copyright 2010 cc_team. All rights reserved.
//

#include "CCAll.h"

#ifdef	OBJC_MACRO

@implementation XmlParser

@synthesize parser;
@synthesize dataBuffer;

- (id)init
{
	MACRO_OBJ_INIT_START_FUNC
	
	self.dataBuffer = nil;
	
	MACRO_OBJ_INIT_END_FUNC
}


- (void)dealloc
{
	[dataBuffer release];
	[parser release];
	[super dealloc];
}


- (BOOL)startParse:(NSString *) dataBuffer parsedData : (BaseXmlDataInfo*) baseXmlDataInfoPtr
{
	return TRUE;
}


//回调: 开始解析元素
- (void)parser:(NSXMLParser *)parser didStartElement:(NSString *)elementName
  namespaceURI:(NSString *)namespaceURI 
 qualifiedName:(NSString *)qualifiedName 
	attributes:(NSDictionary *)attributeDict
{
}


//回调: 解析元素数据
-(void)parser:(NSXMLParser *)parser foundCharacters:(NSString *)string
{
}


//回调: 解析元素尾
- (void)parser:(NSXMLParser *)parser didEndElement:(NSString *)elementName
  namespaceURI:(NSString *)namespaceURI 
 qualifiedName:(NSString *)qName
{
}


//解析过程出现错误
- (void)parser:(NSXMLParser *)parser parseErrorOccurred:(NSError *)parseError
{
}


@end

#endif	//OBJC_MACRO
